(function () {
    angular.module('app')
        .factory('OrderInfoFactory',fn);
    function fn(urlCnst) {
        var self = {};
        self.acceptOrder = function (orderId, cb) {
            urlCnst.post('accept-order' + orderId, cb)
        };
        self.getOrderInfo = function (orderId, cb) {
            urlCnst.get('order-info' + orderId, cb)
        };
        self.denyOrder = function (orderId, cb) {
            urlCnst.post('deny-order' + orderId,cb);
        };

        return self;
    }
})();